import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from "react-redux";
import { Switch, Route, BrowserRouter } from "react-router-dom";
import App from './components/App/App';
import AuthRoute from './components/AuthRoute/AuthRoute';
import registerServiceWorker from './registerServiceWorker';

import './index.scss';
import './nprogress.css';
import 'font-awesome/css/font-awesome.min.css';
import store from './redux/index.redux';


ReactDOM.render((
  <Provider store={store}>
    <BrowserRouter>
      <div>
        <AuthRoute />
        <Switch>
          <Route path="/" component={App}/>
        </Switch>
      </div>
    </BrowserRouter>
  </Provider>
), document.getElementById('root'));
registerServiceWorker();
